package com.ymatou.iapi.productviolate.service;

import java.util.Arrays;
import java.util.List;

import org.json.JSONArray;
import org.json.JSONObject;

import com.ymttest.business.YmatouAutoTestCall;
import com.ymttest.utils.MapUtil;

public class GetProductViolateRemarksCall extends YmatouAutoTestCall {
	protected static String opurl ="/api/Violate/GetProductViolateRemarks";
	
	public GetProductViolateRemarksCall() {
		super("http://productviolate.iapi.ymatou.com/",opurl,"POST","JSON");
	}
	
	
	public JSONObject call(List<String> prodlist){
		
		return this.callAndGetReturnData(MapUtil.hashMap("ProductIds",new JSONArray(prodlist)));
		
	}
	
	
	@Override
	public void addDefHeader() {
		client.addHeader("Content-Type", "application/json; charset=UTF-8");
	}
	
	public static void main(String args[]){
		System.out.println(new GetProductViolateRemarksCall().call(Arrays.asList("b793855f-0e5b-4b44-9f84-79840f270490")).toString());
	}
	
}
